<template>
<div>登陆页面</div>
<br>

<div>
    账户

    <el-input v-model="userValue"/>
</div>
<br>

<div>
    密码
    <el-input v-model="passValue"/>
</div>
<br>
<div><button @keyup.enter="log">登录</button>
</div>
<center><img  :src="pic" width="500px">
</center>
</template>


<script setup>
import PNG from './images/OIP-7.jpg'

import { ref} from 'vue';
const userValue = ref("");
const passValue = ref("")
const pic=ref("")
function log(){
    if(userValue.value != 'admin' && passValue.value != '123456'){
        alert("用户或密码错误");
    }else{

        alert("登陆成功")
        pic.value=PNG
    }
}

</script>